package com.study.controller.FDcontroller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.study.model.pojo.FDpojo.SalesReceipt;
import com.study.service.FDservice.SalesReceiptServices;

@Controller
public class SalesReceiptController {
	@Autowired
	SalesReceiptServices srs;
	
	//访问地址：http://localhost:8089/all_SalesReceipt 
	@GetMapping("/all_SalesReceipt")
	@ResponseBody  //将List集合以JSON数组的形式返回，页面不跳转
	/**
	  *  获取所有销售信息
	 * @return
	 */
	public List<SalesReceipt> allSalesReceipt(){
		System.out.println("123444");
		return srs.selectAll();
	}
}
